package action;

import java.util.ArrayList;
import java.util.Date;
import java.util.HashMap;
import java.util.List;

import com.opensymphony.xwork2.ActionContext;

import basic.PageInfo;
import basic.QuerySet;
import basic.ResultSet;
import basic.SortInfo;
import common.BaseAction;
import entities.TBc;
import entities.TCard;
import entities.TCb;
import entities.TMerchant;
import entities.TMsm;
import entities.TTransaction;
import interfaces.IBcService;
import interfaces.ICardService;
import interfaces.ICbService;
import interfaces.IMerchantService;
import interfaces.IMsmService;
import interfaces.ITransactionService;
import util.ParameterUtil;
import utils.DateUtil;
import utils.ExcelUtil;
import utils.StringUtil;
import views.VTransactionCard;

public class TransactionAction extends BaseAction {

	/**
	 * 
	 */
	private static final long serialVersionUID = 7507534255609348887L;

	private ITransactionService transactionService;
	private ICardService cardService;
	private IMerchantService merchantService;
	private IMsmService msmService;
	private IBcService bcService;
	private ICbService cbService;

	private TCard cardBean;
	private TMerchant merchantBean;
	private TTransaction transactionBean;

	private List<TTransaction> transactionList;
	private List<TMsm> msmList;
	private List<TBc> bcList;
	private List<TCb> cbList;
	private List<VTransactionCard> transactionCardList;

	private String txnNo;
	private String txnNos;
	private String crdNo;
	private String merNo;
	private String txnName;
	private String txnOrder;
	private String txnSite;
	private String txnProduct;
	private String txnNotify;
	private String txnCur;
	private Double txnLoc;
	private Double txnRate;
	private Double txnAmount;
	private Double txnRemain;
	private String txnRefund;
	private String txnRefuse;
	private String txnFreeze;
	private String txnLogic;
	private String txnSettle;
	private String txnDanger;
	private String txnVisible;
	private String txnState;
	private Date txnDate;
	private Date txnDateTop;
	private Date txnDateEnd;
	private String txnRemark;
	private Integer txnCount;
	private Double txnTotal;

	private Boolean crdJoin = new Boolean(false);
	private String crdNos;
	private String crdIp;
	private String crdOs;
	private String crdBrowser;
	private String crdFinger;
	private String crdLocale;
	private String crdTiming;
	private String crdCode;
	private String crdBin;
	private String crdType;
	private String crdFake;
	private String crdNumber;
	private String crdExpire;
	private String crdCvv;
	private String crdCfname;
	private String crdClname;
	private String crdCphone;
	private String crdCemail;
	private String crdCcountry;
	private String crdCstate;
	private String crdCcity;
	private String crdCaddr;
	private String crdCzip;
	private String crdHfname;
	private String crdHlname;
	private String crdHphone;
	private String crdHemail;
	private String crdHcountry;
	private String crdHstate;
	private String crdHcity;
	private String crdHaddr;
	private String crdHzip;
	private String crdState;
	private Date crdDate;
	private Date crdDateTop;
	private Date crdDateEnd;
	private String crdRemark;

	// 展示对象
	public String show() throws Exception {
		if (!transactionService.exist(txnNo)) {
			addActionError("数据不存在");
			return INFO;
		} else {
			transactionBean = transactionService.fetch(txnNo);
			cardBean = cardService.fetch(transactionBean.getCrdNo());
			merchantBean = merchantService.fetch(transactionBean.getMerNo());

			QuerySet<Object> querySet = new QuerySet<Object>();
			HashMap<String, Object> paramMap = new HashMap<String, Object>();
			SortInfo sortInfo = new SortInfo();

			sortInfo = new SortInfo();
			sortInfo.setSortField("bcDate");
			sortInfo.setSortOrder(new Boolean(true));
			paramMap = new HashMap<String, Object>();
			paramMap.put("txnNo", transactionBean.getTxnNo());
			querySet.setPageInfo(new PageInfo(1, Integer.MAX_VALUE));
			querySet.setParamMap(paramMap);
			querySet.setSortInfo(sortInfo);
			bcList = bcService.search(querySet).getResultList();

			sortInfo = new SortInfo();
			sortInfo.setSortField("cbDate");
			sortInfo.setSortOrder(new Boolean(true));
			paramMap = new HashMap<String, Object>();
			paramMap.put("txnNo", transactionBean.getTxnNo());
			querySet.setPageInfo(new PageInfo(1, Integer.MAX_VALUE));
			querySet.setParamMap(paramMap);
			querySet.setSortInfo(sortInfo);
			cbList = cbService.search(querySet).getResultList();

			sortInfo = new SortInfo();
			sortInfo.setSortField("msmDate");
			sortInfo.setSortOrder(new Boolean(true));
			paramMap = new HashMap<String, Object>();
			paramMap.put("msmTxn", transactionBean.getTxnNo());
			querySet.setPageInfo(new PageInfo(1, Integer.MAX_VALUE));
			querySet.setParamMap(paramMap);
			querySet.setSortInfo(sortInfo);
			msmList = msmService.search(querySet).getResultList();

			return SUCCESS;
		}
	}

	// 列表展示
	public String listlogic() throws Exception {
		QuerySet<Object> querySet = new QuerySet<Object>();

		HashMap<String, Object> paramMap = new HashMap<String, Object>();
		paramMap.put("txnDefault", ActionContext.getContext().getSession().get("query").toString());
		paramMap.put("txnNo", StringUtil.split(txnNo));
		paramMap.put("crdNo", StringUtil.split(crdNo));
		paramMap.put("merNo", merNo);
		paramMap.put("txnName", txnName);
		paramMap.put("txnOrder", txnOrder);
		paramMap.put("txnSite", txnSite);
		paramMap.put("txnProduct", txnProduct);
		paramMap.put("txnNotify", txnNotify);
		paramMap.put("txnCur", txnCur);
		paramMap.put("txnLoc", txnLoc);
		paramMap.put("txnRate", txnRate);
		paramMap.put("txnAmount", txnAmount);
		paramMap.put("txnRemain", txnRemain);
		paramMap.put("txnRefund", txnRefund);
		paramMap.put("txnRefuse", txnRefuse);
		paramMap.put("txnFreeze", txnFreeze);
		paramMap.put("txnLogic", "0");
		paramMap.put("txnSettle", txnSettle);
		paramMap.put("txnDanger", txnDanger);
		paramMap.put("txnVisible", txnVisible);
		paramMap.put("txnState", "1");
		paramMap.put("txnDate", ParameterUtil.dateCombin(txnDateTop, txnDateEnd));
		paramMap.put("txnRemark", txnRemark);

		SortInfo sortInfo = new SortInfo();
		sortInfo.setSortField((StringUtil.isEmpty(sortField)) ? "txnDate" : sortField);
		sortInfo.setSortOrder(sortOrder);

		querySet.setPageInfo(new PageInfo(pageIndex, pageSize));
		querySet.setSortInfo(sortInfo);
		querySet.setParamMap(paramMap);

		ResultSet<TTransaction> resultSet = transactionService.search(querySet);
		transactionList = resultSet.getResultList();
		pageInfo = resultSet.getPageInfo();
		return SUCCESS;
	}

	// 列表展示
	public String view() throws Exception {
		QuerySet<Object> querySet = new QuerySet<Object>();

		HashMap<String, Object> paramMap = new HashMap<String, Object>();
		paramMap.put("txnDefault", ActionContext.getContext().getSession().get("query").toString());
		paramMap.put("txnNo", StringUtil.split(txnNo));
		paramMap.put("crdNo", StringUtil.split(crdNo));
		paramMap.put("merNo", merNo);
		paramMap.put("txnName", txnName);
		paramMap.put("txnOrder", txnOrder);
		paramMap.put("txnSite", txnSite);
		paramMap.put("txnProduct", txnProduct);
		paramMap.put("txnNotify", txnNotify);
		paramMap.put("txnCur", txnCur);
		paramMap.put("txnLoc", txnLoc);
		paramMap.put("txnRate", txnRate);
		paramMap.put("txnAmount", txnAmount);
		paramMap.put("txnRemain", txnRemain);
		paramMap.put("txnRefund", txnRefund);
		paramMap.put("txnRefuse", txnRefuse);
		paramMap.put("txnFreeze", txnFreeze);
		paramMap.put("txnLogic", txnLogic);
		paramMap.put("txnSettle", txnSettle);
		paramMap.put("txnDanger", txnDanger);
		paramMap.put("txnVisible", txnVisible);
		paramMap.put("txnState", txnState);
		paramMap.put("txnDate", ParameterUtil.dateCombin(txnDateTop, txnDateEnd));
		paramMap.put("txnRemark", txnRemark);
		paramMap.put("crdIp", crdIp);
		paramMap.put("crdOs", crdOs);
		paramMap.put("crdBrowser", crdBrowser);
		paramMap.put("crdFinger", crdFinger);
		paramMap.put("crdLocale", crdLocale);
		paramMap.put("crdTiming", crdTiming);
		paramMap.put("crdCode", crdCode);
		paramMap.put("crdBin", crdBin);
		paramMap.put("crdType", crdType);
		paramMap.put("crdFake", crdFake);
		paramMap.put("crdNumber", crdNumber);
		paramMap.put("crdCfname", crdCfname);
		paramMap.put("crdClname", crdClname);
		paramMap.put("crdCphone", crdCphone);
		paramMap.put("crdCemail", crdCemail);
		paramMap.put("crdCcountry", crdCcountry);
		paramMap.put("crdCstate", crdCstate);
		paramMap.put("crdCcity", crdCcity);
		paramMap.put("crdCaddr", crdCaddr);
		paramMap.put("crdCzip", crdCzip);
		paramMap.put("crdHfname", crdHfname);
		paramMap.put("crdHlname", crdHlname);
		paramMap.put("crdHphone", crdHphone);
		paramMap.put("crdHemail", crdHemail);
		paramMap.put("crdHcountry", crdHcountry);
		paramMap.put("crdHstate", crdHstate);
		paramMap.put("crdHcity", crdHcity);
		paramMap.put("crdHaddr", crdHaddr);
		paramMap.put("crdHzip", crdHzip);
		paramMap.put("crdState", crdState);
		paramMap.put("crdDate", ParameterUtil.dateCombin(crdDateTop, crdDateEnd));
		paramMap.put("crdRemark", crdRemark);

		SortInfo sortInfo = new SortInfo();
		sortInfo.setSortField((StringUtil.isEmpty(sortField)) ? "txnDate" : sortField);
		sortInfo.setSortOrder(sortOrder);

		querySet.setPageInfo(new PageInfo(pageIndex, pageSize));
		querySet.setSortInfo(sortInfo);
		querySet.setParamMap(paramMap);

		ResultSet<VTransactionCard> resultSet = transactionService.relate(querySet);
		transactionCardList = resultSet.getResultList();
		pageInfo = resultSet.getPageInfo();
		
		querySet.setPolymerizeInfo("txnAmount");
		txnTotal=transactionService.collect(querySet);
		return SUCCESS;
	}

	// 导出视图 查询条件等同于列表查询条件
	public String educe() throws Exception {
		QuerySet<Object> querySet = new QuerySet<Object>();

		HashMap<String, Object> paramMap = new HashMap<String, Object>();
		paramMap.put("txnDefault", ActionContext.getContext().getSession().get("query").toString());
		paramMap.put("txnNo", StringUtil.split(txnNo));
		paramMap.put("crdNo", StringUtil.split(crdNo));
		paramMap.put("merNo", merNo);
		paramMap.put("txnName", txnName);
		paramMap.put("txnOrder", txnOrder);
		paramMap.put("txnSite", txnSite);
		paramMap.put("txnProduct", txnProduct);
		paramMap.put("txnNotify", txnNotify);
		paramMap.put("txnCur", txnCur);
		paramMap.put("txnLoc", txnLoc);
		paramMap.put("txnRate", txnRate);
		paramMap.put("txnAmount", txnAmount);
		paramMap.put("txnRemain", txnRemain);
		paramMap.put("txnRefund", txnRefund);
		paramMap.put("txnRefuse", txnRefuse);
		paramMap.put("txnFreeze", txnFreeze);
		paramMap.put("txnLogic", txnLogic);
		paramMap.put("txnSettle", txnSettle);
		paramMap.put("txnDanger", txnDanger);
		paramMap.put("txnVisible", txnVisible);
		paramMap.put("txnState", txnState);
		paramMap.put("txnDate", ParameterUtil.dateCombin(txnDateTop, txnDateEnd));
		paramMap.put("txnRemark", txnRemark);
		paramMap.put("crdIp", crdIp);
		paramMap.put("crdOs", crdOs);
		paramMap.put("crdBrowser", crdBrowser);
		paramMap.put("crdFinger", crdFinger);
		paramMap.put("crdLocale", crdLocale);
		paramMap.put("crdTiming", crdTiming);
		paramMap.put("crdCode", crdCode);
		paramMap.put("crdBin", crdBin);
		paramMap.put("crdType", crdType);
		paramMap.put("crdFake", crdFake);
		paramMap.put("crdNumber", crdNumber);
		paramMap.put("crdCfname", crdCfname);
		paramMap.put("crdClname", crdClname);
		paramMap.put("crdCphone", crdCphone);
		paramMap.put("crdCemail", crdCemail);
		paramMap.put("crdCcountry", crdCcountry);
		paramMap.put("crdCstate", crdCstate);
		paramMap.put("crdCcity", crdCcity);
		paramMap.put("crdCaddr", crdCaddr);
		paramMap.put("crdCzip", crdCzip);
		paramMap.put("crdHfname", crdHfname);
		paramMap.put("crdHlname", crdHlname);
		paramMap.put("crdHphone", crdHphone);
		paramMap.put("crdHemail", crdHemail);
		paramMap.put("crdHcountry", crdHcountry);
		paramMap.put("crdHstate", crdHstate);
		paramMap.put("crdHcity", crdHcity);
		paramMap.put("crdHaddr", crdHaddr);
		paramMap.put("crdHzip", crdHzip);
		paramMap.put("crdState", crdState);
		paramMap.put("crdDate", ParameterUtil.dateCombin(crdDateTop, crdDateEnd));
		paramMap.put("crdRemark", crdRemark);

		SortInfo sortInfo = new SortInfo();
		sortInfo.setSortField((StringUtil.isEmpty(sortField)) ? "txnDate" : sortField);
		sortInfo.setSortOrder(sortOrder);
		
		querySet.setPageInfo(new PageInfo(pageIndex, 5000));
		querySet.setSortInfo(sortInfo);
		querySet.setParamMap(paramMap);

		ResultSet<VTransactionCard> resultSet = transactionService.relate(querySet);
		transactionCardList = resultSet.getResultList();

		List<String> fieldHead = new ArrayList<String>();
		fieldHead.add("编号");
		fieldHead.add("卡编号");
		fieldHead.add("名称");
		fieldHead.add("商户订单号");
		fieldHead.add("来源网站");
		fieldHead.add("产品信息");
		fieldHead.add("商户通知地址");
		fieldHead.add("原交易币种");
		fieldHead.add("原交易金额");
		fieldHead.add("实时汇率");
		fieldHead.add("交易金额");
		fieldHead.add("交易余额");
		fieldHead.add("退款状态");
		fieldHead.add("拒付状态");
		fieldHead.add("冻结状态");
		fieldHead.add("发货状态");
		fieldHead.add("结算状态");
		fieldHead.add("风险状态");
		fieldHead.add("交易状态");
		fieldHead.add("发生日期日期");
		fieldHead.add("发生日期时间");
		fieldHead.add("交易备注");

		fieldHead.add("ip地址");
		fieldHead.add("操作系统");
		fieldHead.add("浏览器");
		fieldHead.add("语言");
		fieldHead.add("时区");
		fieldHead.add("ip国家码");
		fieldHead.add("bin国家码");
		fieldHead.add("类型");
		fieldHead.add("伪卡号");
		fieldHead.add("卡号");
		fieldHead.add("收货人firstname");
		fieldHead.add("收货人lastname");
		fieldHead.add("收货人电话");
		fieldHead.add("收货人邮件");
		fieldHead.add("收货人国家");
		fieldHead.add("收货人州/省");
		fieldHead.add("收货人城市");
		fieldHead.add("收货人地址");
		fieldHead.add("收货人邮编");
		fieldHead.add("持卡人firstname");
		fieldHead.add("持卡人lastname");
		fieldHead.add("持卡人电话");
		fieldHead.add("持卡人邮箱");
		fieldHead.add("持卡人国家");
		fieldHead.add("持卡人州/省");
		fieldHead.add("持卡人城市");
		fieldHead.add("持卡人地址");
		fieldHead.add("持卡人邮编");
		fieldHead.add("状态");
		fieldHead.add("日期日期");
		fieldHead.add("日期时间");
		fieldHead.add("备注");

		List<List<String>> fieldData = new ArrayList<List<String>>();

		for (VTransactionCard transactionCardBean : transactionCardList) {
			List<String> fieldItem = new ArrayList<String>();
			fieldItem.add(transactionCardBean.getTxnNo());
			fieldItem.add(transactionCardBean.getCrdNo());
			fieldItem.add(transactionCardBean.getTxnName());
			fieldItem.add(transactionCardBean.getTxnOrder());
			fieldItem.add(transactionCardBean.getTxnSite());
			fieldItem.add(transactionCardBean.getTxnProduct());
			fieldItem.add(transactionCardBean.getTxnNotify());
			fieldItem.add(transactionCardBean.getTxnCur());
			fieldItem.add(transactionCardBean.getTxnLoc().toString());
			fieldItem.add(transactionCardBean.getTxnRate().toString());
			fieldItem.add(transactionCardBean.getTxnAmount().toString());
			fieldItem.add(transactionCardBean.getTxnRemain().toString());
			fieldItem.add((transactionCardBean.getTxnRefund().equals("0")) ? "无效" : "有效");
			fieldItem.add((transactionCardBean.getTxnRefuse().equals("0")) ? "无效" : "有效");
			fieldItem.add((transactionCardBean.getTxnFreeze().equals("0")) ? "无效" : "有效");
			fieldItem.add((transactionCardBean.getTxnLogic().equals("0")) ? "无效" : "有效");
			fieldItem.add((transactionCardBean.getTxnSettle().equals("0")) ? "无效" : "有效");
			fieldItem.add((transactionCardBean.getTxnDanger().equals("0")) ? "无效" : "有效");
			fieldItem.add((transactionCardBean.getTxnState().equals("0")) ? "无效" : "有效");
			fieldItem.add(DateUtil.format(transactionCardBean.getTxnDate(), DateUtil.DATE));
			fieldItem.add(DateUtil.format(transactionCardBean.getTxnDate(), DateUtil.TIME));
			fieldItem.add(transactionCardBean.getTxnRemark());

			fieldItem.add(transactionCardBean.getCrdIp());
			fieldItem.add(transactionCardBean.getCrdOs());
			fieldItem.add(transactionCardBean.getCrdBrowser());
			fieldItem.add(transactionCardBean.getCrdLocale());
			fieldItem.add(transactionCardBean.getCrdTiming());
			fieldItem.add(transactionCardBean.getCrdCode());
			fieldItem.add(transactionCardBean.getCrdBin());
			fieldItem.add(transactionCardBean.getCrdType());
			fieldItem.add(transactionCardBean.getCrdFake());
			fieldItem.add(transactionCardBean.getCrdNumber());
			fieldItem.add(transactionCardBean.getCrdCfname());
			fieldItem.add(transactionCardBean.getCrdClname());
			fieldItem.add(transactionCardBean.getCrdCphone());
			fieldItem.add(transactionCardBean.getCrdCemail());
			fieldItem.add(transactionCardBean.getCrdCcountry());
			fieldItem.add(transactionCardBean.getCrdCstate());
			fieldItem.add(transactionCardBean.getCrdCcity());
			fieldItem.add(transactionCardBean.getCrdCaddr());
			fieldItem.add(transactionCardBean.getCrdCzip());
			fieldItem.add(transactionCardBean.getCrdHfname());
			fieldItem.add(transactionCardBean.getCrdHlname());
			fieldItem.add(transactionCardBean.getCrdHphone());
			fieldItem.add(transactionCardBean.getCrdHemail());
			fieldItem.add(transactionCardBean.getCrdHcountry());
			fieldItem.add(transactionCardBean.getCrdHstate());
			fieldItem.add(transactionCardBean.getCrdHcity());
			fieldItem.add(transactionCardBean.getCrdHaddr());
			fieldItem.add(transactionCardBean.getCrdHzip());
			fieldItem.add((transactionCardBean.getCrdState().equals("0")) ? "无效" : "有效");
			fieldItem.add(DateUtil.format(transactionCardBean.getCrdDate(), DateUtil.DATE));
			fieldItem.add(DateUtil.format(transactionCardBean.getCrdDate(), DateUtil.TIME));
			fieldItem.add(transactionCardBean.getCrdRemark());
			fieldData.add(fieldItem);
		}

		inputStream = ExcelUtil.excel(fieldHead, fieldData);
		return SUCCESS;
	}

	////////////////////// ---------------------------//////////////////////////////////////////////////////////////////////////////////////////////////////////////
	////////////////////// ---------------------------//////////////////////////////////////////////////////////////////////////////////////////////////////////////
	////////////////////// ---------------------------//////////////////////////////////////////////////////////////////////////////////////////////////////////////

	public ITransactionService getTransactionService() {
		return transactionService;
	}

	public void setTransactionService(ITransactionService transactionService) {
		this.transactionService = transactionService;
	}

	public TTransaction getTransactionBean() {
		return transactionBean;
	}

	public void setTransactionBean(TTransaction transactionBean) {
		this.transactionBean = transactionBean;
	}

	public List<TTransaction> getTransactionList() {
		return transactionList;
	}

	public void setTransactionList(List<TTransaction> transactionList) {
		this.transactionList = transactionList;
	}

	public String getTxnNo() {
		return txnNo;
	}

	public void setTxnNo(String txnNo) {
		this.txnNo = txnNo;
	}

	public String getTxnNos() {
		return txnNos;
	}

	public void setTxnNos(String txnNos) {
		this.txnNos = txnNos;
	}

	public String getCrdNo() {
		return crdNo;
	}

	public void setCrdNo(String crdNo) {
		this.crdNo = crdNo;
	}

	public String getMerNo() {
		return merNo;
	}

	public void setMerNo(String merNo) {
		this.merNo = merNo;
	}

	public String getTxnName() {
		return txnName;
	}

	public void setTxnName(String txnName) {
		this.txnName = txnName;
	}

	public String getTxnOrder() {
		return txnOrder;
	}

	public void setTxnOrder(String txnOrder) {
		this.txnOrder = txnOrder;
	}

	public String getTxnSite() {
		return txnSite;
	}

	public void setTxnSite(String txnSite) {
		this.txnSite = txnSite;
	}

	public String getTxnProduct() {
		return txnProduct;
	}

	public void setTxnProduct(String txnProduct) {
		this.txnProduct = txnProduct;
	}

	public String getTxnNotify() {
		return txnNotify;
	}

	public void setTxnNotify(String txnNotify) {
		this.txnNotify = txnNotify;
	}

	public String getTxnCur() {
		return txnCur;
	}

	public void setTxnCur(String txnCur) {
		this.txnCur = txnCur;
	}

	public Double getTxnLoc() {
		return txnLoc;
	}

	public void setTxnLoc(Double txnLoc) {
		this.txnLoc = txnLoc;
	}

	public Double getTxnRate() {
		return txnRate;
	}

	public void setTxnRate(Double txnRate) {
		this.txnRate = txnRate;
	}

	public Double getTxnAmount() {
		return txnAmount;
	}

	public void setTxnAmount(Double txnAmount) {
		this.txnAmount = txnAmount;
	}

	public Double getTxnRemain() {
		return txnRemain;
	}

	public void setTxnRemain(Double txnRemain) {
		this.txnRemain = txnRemain;
	}

	public String getTxnRefund() {
		return txnRefund;
	}

	public void setTxnRefund(String txnRefund) {
		this.txnRefund = txnRefund;
	}

	public String getTxnRefuse() {
		return txnRefuse;
	}

	public void setTxnRefuse(String txnRefuse) {
		this.txnRefuse = txnRefuse;
	}

	public String getTxnFreeze() {
		return txnFreeze;
	}

	public void setTxnFreeze(String txnFreeze) {
		this.txnFreeze = txnFreeze;
	}

	public String getTxnLogic() {
		return txnLogic;
	}

	public void setTxnLogic(String txnLogic) {
		this.txnLogic = txnLogic;
	}

	public String getTxnSettle() {
		return txnSettle;
	}

	public void setTxnSettle(String txnSettle) {
		this.txnSettle = txnSettle;
	}

	public String getTxnDanger() {
		return txnDanger;
	}

	public void setTxnDanger(String txnDanger) {
		this.txnDanger = txnDanger;
	}

	public String getTxnVisible() {
		return txnVisible;
	}

	public void setTxnVisible(String txnVisible) {
		this.txnVisible = txnVisible;
	}

	public String getTxnState() {
		return txnState;
	}

	public void setTxnState(String txnState) {
		this.txnState = txnState;
	}

	public Date getTxnDate() {
		return txnDate;
	}

	public void setTxnDate(Date txnDate) {
		this.txnDate = txnDate;
	}

	public Date getTxnDateTop() {
		return txnDateTop;
	}

	public void setTxnDateTop(Date txnDateTop) {
		this.txnDateTop = txnDateTop;
	}

	public Date getTxnDateEnd() {
		return txnDateEnd;
	}

	public void setTxnDateEnd(Date txnDateEnd) {
		this.txnDateEnd = txnDateEnd;
	}

	public String getTxnRemark() {
		return txnRemark;
	}

	public void setTxnRemark(String txnRemark) {
		this.txnRemark = txnRemark;
	}

	public List<VTransactionCard> getTransactionCardList() {
		return transactionCardList;
	}

	public void setTransactionCardList(List<VTransactionCard> transactionCardList) {
		this.transactionCardList = transactionCardList;
	}

	public String getCrdNos() {
		return crdNos;
	}

	public void setCrdNos(String crdNos) {
		this.crdNos = crdNos;
	}

	public String getCrdIp() {
		return crdIp;
	}

	public void setCrdIp(String crdIp) {
		this.crdIp = crdIp;
	}

	public String getCrdOs() {
		return crdOs;
	}

	public void setCrdOs(String crdOs) {
		this.crdOs = crdOs;
	}

	public String getCrdBrowser() {
		return crdBrowser;
	}

	public void setCrdBrowser(String crdBrowser) {
		this.crdBrowser = crdBrowser;
	}

	public String getCrdFinger() {
		return crdFinger;
	}

	public void setCrdFinger(String crdFinger) {
		this.crdFinger = crdFinger;
	}

	public String getCrdLocale() {
		return crdLocale;
	}

	public void setCrdLocale(String crdLocale) {
		this.crdLocale = crdLocale;
	}

	public String getCrdTiming() {
		return crdTiming;
	}

	public void setCrdTiming(String crdTiming) {
		this.crdTiming = crdTiming;
	}

	public String getCrdCode() {
		return crdCode;
	}

	public void setCrdCode(String crdCode) {
		this.crdCode = crdCode;
	}

	public String getCrdBin() {
		return crdBin;
	}

	public void setCrdBin(String crdBin) {
		this.crdBin = crdBin;
	}

	public String getCrdType() {
		return crdType;
	}

	public void setCrdType(String crdType) {
		this.crdType = crdType;
	}

	public String getCrdFake() {
		return crdFake;
	}

	public void setCrdFake(String crdFake) {
		this.crdFake = crdFake;
	}

	public String getCrdNumber() {
		return crdNumber;
	}

	public void setCrdNumber(String crdNumber) {
		this.crdNumber = crdNumber;
	}

	public String getCrdExpire() {
		return crdExpire;
	}

	public void setCrdExpire(String crdExpire) {
		this.crdExpire = crdExpire;
	}

	public String getCrdCvv() {
		return crdCvv;
	}

	public void setCrdCvv(String crdCvv) {
		this.crdCvv = crdCvv;
	}

	public String getCrdCfname() {
		return crdCfname;
	}

	public void setCrdCfname(String crdCfname) {
		this.crdCfname = crdCfname;
	}

	public String getCrdClname() {
		return crdClname;
	}

	public void setCrdClname(String crdClname) {
		this.crdClname = crdClname;
	}

	public String getCrdCphone() {
		return crdCphone;
	}

	public void setCrdCphone(String crdCphone) {
		this.crdCphone = crdCphone;
	}

	public String getCrdCemail() {
		return crdCemail;
	}

	public void setCrdCemail(String crdCemail) {
		this.crdCemail = crdCemail;
	}

	public String getCrdCcountry() {
		return crdCcountry;
	}

	public void setCrdCcountry(String crdCcountry) {
		this.crdCcountry = crdCcountry;
	}

	public String getCrdCstate() {
		return crdCstate;
	}

	public void setCrdCstate(String crdCstate) {
		this.crdCstate = crdCstate;
	}

	public String getCrdCcity() {
		return crdCcity;
	}

	public void setCrdCcity(String crdCcity) {
		this.crdCcity = crdCcity;
	}

	public String getCrdCaddr() {
		return crdCaddr;
	}

	public void setCrdCaddr(String crdCaddr) {
		this.crdCaddr = crdCaddr;
	}

	public String getCrdCzip() {
		return crdCzip;
	}

	public void setCrdCzip(String crdCzip) {
		this.crdCzip = crdCzip;
	}

	public String getCrdHfname() {
		return crdHfname;
	}

	public void setCrdHfname(String crdHfname) {
		this.crdHfname = crdHfname;
	}

	public String getCrdHlname() {
		return crdHlname;
	}

	public void setCrdHlname(String crdHlname) {
		this.crdHlname = crdHlname;
	}

	public String getCrdHphone() {
		return crdHphone;
	}

	public void setCrdHphone(String crdHphone) {
		this.crdHphone = crdHphone;
	}

	public String getCrdHemail() {
		return crdHemail;
	}

	public void setCrdHemail(String crdHemail) {
		this.crdHemail = crdHemail;
	}

	public String getCrdHcountry() {
		return crdHcountry;
	}

	public void setCrdHcountry(String crdHcountry) {
		this.crdHcountry = crdHcountry;
	}

	public String getCrdHstate() {
		return crdHstate;
	}

	public void setCrdHstate(String crdHstate) {
		this.crdHstate = crdHstate;
	}

	public String getCrdHcity() {
		return crdHcity;
	}

	public void setCrdHcity(String crdHcity) {
		this.crdHcity = crdHcity;
	}

	public String getCrdHaddr() {
		return crdHaddr;
	}

	public void setCrdHaddr(String crdHaddr) {
		this.crdHaddr = crdHaddr;
	}

	public String getCrdHzip() {
		return crdHzip;
	}

	public void setCrdHzip(String crdHzip) {
		this.crdHzip = crdHzip;
	}

	public String getCrdState() {
		return crdState;
	}

	public void setCrdState(String crdState) {
		this.crdState = crdState;
	}

	public Date getCrdDate() {
		return crdDate;
	}

	public void setCrdDate(Date crdDate) {
		this.crdDate = crdDate;
	}

	public Date getCrdDateTop() {
		return crdDateTop;
	}

	public void setCrdDateTop(Date crdDateTop) {
		this.crdDateTop = crdDateTop;
	}

	public Date getCrdDateEnd() {
		return crdDateEnd;
	}

	public void setCrdDateEnd(Date crdDateEnd) {
		this.crdDateEnd = crdDateEnd;
	}

	public String getCrdRemark() {
		return crdRemark;
	}

	public void setCrdRemark(String crdRemark) {
		this.crdRemark = crdRemark;
	}

	public Boolean getCrdJoin() {
		return crdJoin;
	}

	public void setCrdJoin(Boolean crdJoin) {
		this.crdJoin = crdJoin;
	}

	public IBcService getBcService() {
		return bcService;
	}

	public void setBcService(IBcService bcService) {
		this.bcService = bcService;
	}

	public ICbService getCbService() {
		return cbService;
	}

	public void setCbService(ICbService cbService) {
		this.cbService = cbService;
	}

	public TCard getCardBean() {
		return cardBean;
	}

	public void setCardBean(TCard cardBean) {
		this.cardBean = cardBean;
	}

	public TMerchant getMerchantBean() {
		return merchantBean;
	}

	public void setMerchantBean(TMerchant merchantBean) {
		this.merchantBean = merchantBean;
	}

	public List<TBc> getBcList() {
		return bcList;
	}

	public void setBcList(List<TBc> bcList) {
		this.bcList = bcList;
	}

	public List<TCb> getCbList() {
		return cbList;
	}

	public void setCbList(List<TCb> cbList) {
		this.cbList = cbList;
	}

	public ICardService getCardService() {
		return cardService;
	}

	public void setCardService(ICardService cardService) {
		this.cardService = cardService;
	}

	public IMerchantService getMerchantService() {
		return merchantService;
	}

	public void setMerchantService(IMerchantService merchantService) {
		this.merchantService = merchantService;
	}

	public IMsmService getMsmService() {
		return msmService;
	}

	public void setMsmService(IMsmService msmService) {
		this.msmService = msmService;
	}

	public List<TMsm> getMsmList() {
		return msmList;
	}

	public void setMsmList(List<TMsm> msmList) {
		this.msmList = msmList;
	}

	public Double getTxnTotal() {
		return txnTotal;
	}

	public void setTxnTotal(Double txnTotal) {
		this.txnTotal = txnTotal;
	}

	public Integer getTxnCount() {
		return txnCount;
	}

	public void setTxnCount(Integer txnCount) {
		this.txnCount = txnCount;
	}

	
	

}
